package org.demo.ioc.service;

import org.demo.ioc.facade.CPU;
import org.demo.ioc.facade.Motherboard;
import org.demo.ioc.facade.RAM;

public abstract class AbstractMotherboard implements Motherboard {

	private CPU cpu;

	private RAM ram;

	private boolean power;

	public CPU getCpu() {
		return cpu;
	}

	public RAM getRam() {
		return ram;
	}

	public boolean havePower() {
		return power;
	}

	public void poweron() {
		power = true;
	}

	public void setCpu(CPU cpu) {
		this.cpu = cpu;
	}

	public void setRam(RAM ram) {
		this.ram = ram;
	}

	public void shutdown() {
		power = false;
	}
}
